package com.hui.demo.service.impl;

import com.hui.demo.model.Role;
import com.hui.demo.repository.RoleRepository;
import com.hui.demo.service.RoleService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;

/**
 * 用户角色service实现类
 * @author ziv
 * @date 2019-01-07
 */
@Service
public class RoleServiceImpl implements RoleService {

    @Resource
    private RoleRepository roleRepository;

    @Override
    public Role find(String roleId) {
        return roleRepository.findById(roleId).get();
    }
}
